// import axios from 'axios'
import request from '@/utils/request'
// import request from 'vue-resource'

export function login(mobile, pwd) {
  // this.$http.post(process.env.BASE_API + '/login', { mobile: mobile, pwd: pwd }).then(response => {
  //   console.log(response)
  // })
  return request({
    url: '/login',
    method: 'post',
    data: {
      mobile: mobile,
      pwd: pwd
    }
  })
}

// export function register(data) {
//   return request({
//     url: '/register',
//     method: 'post',
//     param: {
//       data
//     }
//   })
// }

export function passowrReset(data) {
  return request({
    url: '/user/reset',
    method: 'post',
    data
  })
}

export function Auth(data) {
  return request({
    url: '/user/Auth',
    method: 'post',
    data
  })
}

export function logout(data) {
  return request({
    url: '/user/Auth',
    method: 'post',
    data
  })
}
